package com.sky.financelake.bean.dto;

import android.os.Parcel;
import android.os.Parcelable;

public class QuotationDto implements Parcelable {
    private Integer id;
    private String tradeDate;
    private String tsCode;
    private String name;
    private Float closePrice;
    private Float highPrice;
    private Float lowPrice;
    private Float openPrice;
    private String preClosing;
    private String updown;
    private String updownRate;
    private String changeRate;
    private Integer volumn;
    private String volumnAmount;
    private String totalMarketValue;
    private String circulMarketValue;


    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getTradeDate() {
        return tradeDate;
    }

    public void setTradeDate(String tradeDate) {
        this.tradeDate = tradeDate;
    }

    public String getTsCode() {
        return tsCode;
    }

    public void setTsCode(String tsCode) {
        this.tsCode = tsCode;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Float getClosePrice() {
        return closePrice;
    }

    public void setClosePrice(Float closePrice) {
        this.closePrice = closePrice;
    }

    public Float getHighPrice() {
        return highPrice;
    }

    public void setHighPrice(Float highPrice) {
        this.highPrice = highPrice;
    }

    public Float getLowPrice() {
        return lowPrice;
    }

    public void setLowPrice(Float lowPrice) {
        this.lowPrice = lowPrice;
    }

    public Float getOpenPrice() {
        return openPrice;
    }

    public void setOpenPrice(Float openPrice) {
        this.openPrice = openPrice;
    }

    public String getPreClosing() {
        return preClosing;
    }

    public void setPreClosing(String preClosing) {
        this.preClosing = preClosing;
    }

    public String getUpdown() {
        return updown;
    }

    public void setUpdown(String updown) {
        this.updown = updown;
    }

    public String getUpdownRate() {
        return updownRate;
    }

    public void setUpdownRate(String updownRate) {
        this.updownRate = updownRate;
    }

    public String getChangeRate() {
        return changeRate;
    }

    public void setChangeRate(String changeRate) {
        this.changeRate = changeRate;
    }

    public Integer getVolumn() {
        return volumn;
    }

    public void setVolumn(Integer volumn) {
        this.volumn = volumn;
    }

    public String getVolumnAmount() {
        return volumnAmount;
    }

    public void setVolumnAmount(String volumnAmount) {
        this.volumnAmount = volumnAmount;
    }

    public String getTotalMarketValue() {
        return totalMarketValue;
    }

    public void setTotalMarketValue(String totalMarketValue) {
        this.totalMarketValue = totalMarketValue;
    }

    public String getCirculMarketValue() {
        return circulMarketValue;
    }

    public void setCirculMarketValue(String circulMarketValue) {
        this.circulMarketValue = circulMarketValue;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeValue(this.id);
        dest.writeString(this.tradeDate);
        dest.writeString(this.tsCode);
        dest.writeString(this.name);
        dest.writeValue(this.closePrice);
        dest.writeValue(this.highPrice);
        dest.writeValue(this.lowPrice);
        dest.writeValue(this.openPrice);
        dest.writeString(this.preClosing);
        dest.writeString(this.updown);
        dest.writeString(this.updownRate);
        dest.writeString(this.changeRate);
        dest.writeValue(this.volumn);
        dest.writeString(this.volumnAmount);
        dest.writeString(this.totalMarketValue);
        dest.writeString(this.circulMarketValue);
    }

    public void readFromParcel(Parcel source) {
        this.id = (Integer) source.readValue(Integer.class.getClassLoader());
        this.tradeDate = source.readString();
        this.tsCode = source.readString();
        this.name = source.readString();
        this.closePrice = (Float) source.readValue(Float.class.getClassLoader());
        this.highPrice = (Float) source.readValue(Float.class.getClassLoader());
        this.lowPrice = (Float) source.readValue(Float.class.getClassLoader());
        this.openPrice = (Float) source.readValue(Float.class.getClassLoader());
        this.preClosing = source.readString();
        this.updown = source.readString();
        this.updownRate = source.readString();
        this.changeRate = source.readString();
        this.volumn = (Integer) source.readValue(Integer.class.getClassLoader());
        this.volumnAmount = source.readString();
        this.totalMarketValue = source.readString();
        this.circulMarketValue = source.readString();
    }

    public QuotationDto() {
    }

    protected QuotationDto(Parcel in) {
        this.id = (Integer) in.readValue(Integer.class.getClassLoader());
        this.tradeDate = in.readString();
        this.tsCode = in.readString();
        this.name = in.readString();
        this.closePrice = (Float) in.readValue(Float.class.getClassLoader());
        this.highPrice = (Float) in.readValue(Float.class.getClassLoader());
        this.lowPrice = (Float) in.readValue(Float.class.getClassLoader());
        this.openPrice = (Float) in.readValue(Float.class.getClassLoader());
        this.preClosing = in.readString();
        this.updown = in.readString();
        this.updownRate = in.readString();
        this.changeRate = in.readString();
        this.volumn = (Integer) in.readValue(Integer.class.getClassLoader());
        this.volumnAmount = in.readString();
        this.totalMarketValue = in.readString();
        this.circulMarketValue = in.readString();
    }

    public static final Parcelable.Creator<QuotationDto> CREATOR = new Parcelable.Creator<QuotationDto>() {
        @Override
        public QuotationDto createFromParcel(Parcel source) {
            return new QuotationDto(source);
        }

        @Override
        public QuotationDto[] newArray(int size) {
            return new QuotationDto[size];
        }
    };
}
